package com.example.spring.domain;

import lombok.Data;

/**
 * 
 * @TableName companies
 */
@Data
public class Companies {
    /**
     * 
     */
    private Long company_id;

    /**
     * 
     */
    private String company_name;

    /**
     * 
     */
    private String company_person;

    /**
     * 
     */
    private String company_person_phone;

    /**
     * 
     */
    private String company_fax;

    /**
     * 
     */
    private String company_phone;

    /**
     * 
     */
    private String company_email;

    /**
     * 
     */
    private String company_url;

    /**
     * 
     */
    private String company_address;

    /**
     * 
     */
    private String company_context;

    /**
     * 
     */
    private String company_range;

    /**
     * 
     */
    private String company_product;

    /**
     * 
     */
    private String company_type;

    /**
     * 
     */
    private String company_money;

    /**
     * 
     */
    private Integer company_type_id;

    /**
     * 
     */
    private String address;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Companies other = (Companies) that;
        return (this.getCompany_id() == null ? other.getCompany_id() == null : this.getCompany_id().equals(other.getCompany_id()))
            && (this.getCompany_name() == null ? other.getCompany_name() == null : this.getCompany_name().equals(other.getCompany_name()))
            && (this.getCompany_person() == null ? other.getCompany_person() == null : this.getCompany_person().equals(other.getCompany_person()))
            && (this.getCompany_person_phone() == null ? other.getCompany_person_phone() == null : this.getCompany_person_phone().equals(other.getCompany_person_phone()))
            && (this.getCompany_fax() == null ? other.getCompany_fax() == null : this.getCompany_fax().equals(other.getCompany_fax()))
            && (this.getCompany_phone() == null ? other.getCompany_phone() == null : this.getCompany_phone().equals(other.getCompany_phone()))
            && (this.getCompany_email() == null ? other.getCompany_email() == null : this.getCompany_email().equals(other.getCompany_email()))
            && (this.getCompany_url() == null ? other.getCompany_url() == null : this.getCompany_url().equals(other.getCompany_url()))
            && (this.getCompany_address() == null ? other.getCompany_address() == null : this.getCompany_address().equals(other.getCompany_address()))
            && (this.getCompany_context() == null ? other.getCompany_context() == null : this.getCompany_context().equals(other.getCompany_context()))
            && (this.getCompany_range() == null ? other.getCompany_range() == null : this.getCompany_range().equals(other.getCompany_range()))
            && (this.getCompany_product() == null ? other.getCompany_product() == null : this.getCompany_product().equals(other.getCompany_product()))
            && (this.getCompany_type() == null ? other.getCompany_type() == null : this.getCompany_type().equals(other.getCompany_type()))
            && (this.getCompany_money() == null ? other.getCompany_money() == null : this.getCompany_money().equals(other.getCompany_money()))
            && (this.getCompany_type_id() == null ? other.getCompany_type_id() == null : this.getCompany_type_id().equals(other.getCompany_type_id()))
            && (this.getAddress() == null ? other.getAddress() == null : this.getAddress().equals(other.getAddress()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getCompany_id() == null) ? 0 : getCompany_id().hashCode());
        result = prime * result + ((getCompany_name() == null) ? 0 : getCompany_name().hashCode());
        result = prime * result + ((getCompany_person() == null) ? 0 : getCompany_person().hashCode());
        result = prime * result + ((getCompany_person_phone() == null) ? 0 : getCompany_person_phone().hashCode());
        result = prime * result + ((getCompany_fax() == null) ? 0 : getCompany_fax().hashCode());
        result = prime * result + ((getCompany_phone() == null) ? 0 : getCompany_phone().hashCode());
        result = prime * result + ((getCompany_email() == null) ? 0 : getCompany_email().hashCode());
        result = prime * result + ((getCompany_url() == null) ? 0 : getCompany_url().hashCode());
        result = prime * result + ((getCompany_address() == null) ? 0 : getCompany_address().hashCode());
        result = prime * result + ((getCompany_context() == null) ? 0 : getCompany_context().hashCode());
        result = prime * result + ((getCompany_range() == null) ? 0 : getCompany_range().hashCode());
        result = prime * result + ((getCompany_product() == null) ? 0 : getCompany_product().hashCode());
        result = prime * result + ((getCompany_type() == null) ? 0 : getCompany_type().hashCode());
        result = prime * result + ((getCompany_money() == null) ? 0 : getCompany_money().hashCode());
        result = prime * result + ((getCompany_type_id() == null) ? 0 : getCompany_type_id().hashCode());
        result = prime * result + ((getAddress() == null) ? 0 : getAddress().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", company_id=").append(company_id);
        sb.append(", company_name=").append(company_name);
        sb.append(", company_person=").append(company_person);
        sb.append(", company_person_phone=").append(company_person_phone);
        sb.append(", company_fax=").append(company_fax);
        sb.append(", company_phone=").append(company_phone);
        sb.append(", company_email=").append(company_email);
        sb.append(", company_url=").append(company_url);
        sb.append(", company_address=").append(company_address);
        sb.append(", company_context=").append(company_context);
        sb.append(", company_range=").append(company_range);
        sb.append(", company_product=").append(company_product);
        sb.append(", company_type=").append(company_type);
        sb.append(", company_money=").append(company_money);
        sb.append(", company_type_id=").append(company_type_id);
        sb.append(", address=").append(address);
        sb.append("]");
        return sb.toString();
    }
}